<template>
	<van-config-provider :theme="theme">
		<!-- 开启顶部安全区适配 -->
		<!-- <van-nav-bar safe-area-inset-top /> -->
		<router-view />
		<!-- 开启底部安全区适配 -->
		<van-number-keyboard safe-area-inset-bottom />
	</van-config-provider>
</template>

<script setup lang="ts">
import axios from 'axios';

Promise.all([axios.get('jd'), axios.get('jd2')]);
const theme = ref<'light' | 'dark'>('dark');
setInterval(() => (theme.value = theme.value === 'dark' ? 'light' : 'dark'), 2500);
</script>
<style lang="scss" scoped>
.van-theme-dark .van-config-provider {
	height: 100vh;
	width: 100vw;
	overflow: auto;
	color: #f5f5f5;
	background-color: black;
}
</style>
